//
//  ZKTransitionTestDemoSecondVC.m
//  朱凯的工具箱
//
//  Created by pro on 17/5/12.
//  Copyright © 2017年 zhukai. All rights reserved.
//

#import "ZKTransitionTestDemoSecondVC.h"

#import "UIViewController+ZKViewControllerTransition.h"


@interface ZKTransitionTestDemoSecondVC ()

@end

@implementation ZKTransitionTestDemoSecondVC

- (void)viewDidLoad {
    [super viewDidLoad];
    
    self.view.backgroundColor = [UIColor cyanColor];
    
    UIButton *button = [UIButton buttonWithType:UIButtonTypeCustom];
    [button setFrame:CGRectMake(100, 100, 100, 100)];
    [button setBackgroundColor:[UIColor blackColor]];
    [button setTitle:@"返回" forState:UIControlStateNormal];
    [button setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
    [button addTarget:self action:@selector(tap) forControlEvents:UIControlEventTouchUpInside];
    [self.view addSubview:button];
    
    UIButton *button2 = [UIButton buttonWithType:UIButtonTypeCustom];
    [button2 setFrame:CGRectMake(220, 100, 100, 100)];
    [button2 setBackgroundColor:[UIColor blackColor]];
    [button2 setTitle:@"跳转" forState:UIControlStateNormal];
    [button2 setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
    [button2 addTarget:self action:@selector(tap2) forControlEvents:UIControlEventTouchUpInside];
    [self.view addSubview:button2];
    
//    [self zk_registerBackInteractive];
}

- (void)tap {
    
    [self dismissViewControllerAnimated:YES completion:nil];
}
- (void)tap2 {
    
    ZKTransitionTestDemoSecondVC *vc = [ZKTransitionTestDemoSecondVC new];
    [self zk_presentViewController:vc animator:nil backInteractive:YES];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
